﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Net.Http;
using System.Web.Http;
using WebAPI.Models;

namespace WebAPI.Controllers
{
    public class GoodsImagesController : BaseApiController
    {
        /// <summary>
        /// 根据商品id获取图片
        /// </summary>
        /// <returns></returns>
        public IEnumerable<GoodsImages> GetListByGoodsId(int id)
        {
            var list = from g in db.GoodsImages where g.GoodsId == id select g;
            return list;
        }
    }
}
